package com.bdqn.jk.service;

import com.bdqn.jk.controller.vo.NewBeeMallIndexCategoryVO;
import com.bdqn.jk.controller.vo.SearchPageCategoryVO;
import com.bdqn.jk.entity.GoodsCategory;
import com.bdqn.jk.util.PageQueryUtil;
import com.bdqn.jk.util.PageResult;

import java.util.List;

public interface GoodsCategoryService {

    PageResult getCategorisPage(PageQueryUtil pageUtil);

    String saveCategory(GoodsCategory goodsCategory);

    String updateGoodsCategory(GoodsCategory goodsCategory);

    GoodsCategory getGoodsCategoryById(Long id);

    Boolean deleteBatch(Integer[] ids);

    /**
     * 返回分类数据(首页调用)
     */
    List<NewBeeMallIndexCategoryVO> getCategoriesForIndex();

    /**
     * 返回分类数据(搜索页调用)
     */
    SearchPageCategoryVO getCategoriesForSearch(Long categoryId);

    /**
     * 根据parentId和level获取分类列表
     */
    List<GoodsCategory> selectByLevelAndParentIdsAndNumber(List<Long> parentIds, int categoryLevel);
}
